#ifndef METACENTERSERVERUI_H
#define METACENTERSERVERUI_H

#include <QMainWindow>
#include <QWidget>
#include <QListWidget>
#include <QLabel>
#include <QLineEdit>
#include <QPushButton>
#include <QGridLayout>
#include <QTreeWidgetItem>
#include <QString>

#include "meta_center_server.h"


// QMainWindow::setCentralWidget(),
class MetaCenterServerUi : public QMainWindow
{
    Q_OBJECT

public:
    MetaCenterServerUi(QWidget *parent = nullptr);
    ~MetaCenterServerUi();

public slots:
    void slotCreateServer();
    void UpdateServerHandle(QString, int, MetaCenterServer::MsgKind);

private:
    QWidget *myWidget;
    QListWidget *ContentListWidget;
    QLabel *PortLabel;
    QLineEdit *PortLineEdit;
    QPushButton *CreateBtn;
    QTreeWidget *resourceTree;
    QGridLayout *mainLayout;

    int port;
    MetaCenterServer *server;

};
#endif // METACENTERSERVERUI_H
